import request from '@/utils/request'
export function fetchList(query) {
  return request({
    url: '/mall/channel/page',
    method: 'get',
    params: query
  })
}

export function delObj(id) {
  return request({
    url: '/mall/channel/id/' + id,
    method: 'delete'
  })
}

export function getObj(id) {
  return request({
    url: '/mall/channel/get/' + id,
    method: 'get'
  })
}
export function putObj(obj) {
  return request({
    url: '/mall/channel',
    method: 'put',
    data: obj
  })
}
export function getChannelList() {
  return request({
    url: '/mall/channel/getList/',
    method: 'get'
  })
}
export function addObj(obj) {
  return request({
    url: '/mall/channel',
    method: 'post',
    data: obj
  })
}
